Method for unlocking a mobile terminal, devices using the same, and computer-readable storage media encoding the same

ABSTRACT

Methods for unlocking a mobile terminal can include capturing a face image of a user through a front-facing camera of the mobile terminal in response to a sliding action applied to a sliding module on the mobile terminal; and unlocking the mobile terminal by using the captured face image as a key.

CROSS-REFERENCE TO RELATED APPLICATION

The present application claims priority to Chinese Patent ApplicationNo. 201811224777.0 filed on Oct. 19, 2018, the content of which ishereby incorporated by reference in its entirety.

BACKGROUND

As people's living standards improve, mobile terminals have becomeindispensable in users' daily lives.

To protect users' privacies and secure user account information, mobileterminals typically require a user to unlock the device before normaluse. For example, a user may turn on a mobile terminal's screen througha power button, bring up an unlocking interface, and then input anunlocking password or gesture through the unlocking interface to unlockthe mobile terminal.

SUMMARY

The present disclosure relates generally to the field of mobile terminaltechnologies, and in particular, to methods for unlocking a mobileterminal, as well as devices implementing the same, andcomputer-readable storage media encoding the same.

The present disclosure provides methods for unlocking a mobile terminal,as well as control mechanisms and devices implementing the same, andcomputer-readable storage media encoding the same.

According to a first aspect of the present disclosure, there is provideda method for a user to unlock a mobile terminal, including: capturing aface image of the user through a camera of the mobile terminal inresponse to a sliding action applied to a sliding module of the mobileterminal; and unlocking the mobile terminal by using the captured faceimage of the user as a key.

In some embodiments of the present disclosure, when the user slides thecover, the front camera of the mobile terminal is exposed. At this time,the front camera acquires the face image and unlocks the mobile terminalby using the face image. In the entire unlocking process, the user doesnot need to perform operation steps such as clicking a power button tolight a screen, and inputting an unlocking password or gesture on anunlocking interface, but only needs to slide the cover. Therefore, suchoperation is simple and convenient, and requires less time and labor.

In an implementation of the present disclosure, unlocking the mobileterminal by using the face image includes: comparing features betweenthe face image and a preset face image to obtain a comparison result;and unlocking the mobile terminal when the comparison result indicatesthat the face image and the preset face image are from the same person.

In this implementation, the feature of the face image shot by the frontcamera is compared with that of the preset face image in the mobileterminal to perform unlocking. The mobile terminal can be unlockedsuccessfully only when the face image as captured and the preset faceare from the same person, thereby ensuring the security.

In an implementation of the present disclosure, the method furtherincludes: lighting or turning on a screen and outputting a touchunlocking interface when the comparison result indicates that the faceimage and the preset face image are from different persons.

In this implementation, when the face image unlocking fails, anunlocking interface may be output to allow the user to input a passwordor gesture for unlocking, so that the diversity of the unlocking mannersis increased.

In an implementation of the present disclosure, the method furtherincludes: lighting a screen and outputting a main menu interface afterthe mobile terminal is unlocked.

In this implementation, the screen is not lighted or turned on when thefront camera is exposed, but is lighted after the unlocking issuccessful, so that the user does not need to wait for the unlockingwhen the screen is lighted. Thus, not only is power saved, but also theuser feels that the unlocking speed is higher, improving the userunlocking experience.

In an implementation of the present disclosure, the method furtherincludes: acquiring a sliding event parameter generated by a Hall sensorin the mobile terminal; and determining whether a cover sliding actionoccurs on the mobile terminal according to the sliding event parameter.

In this implementation, when the user slides the cover, the Hall sensorin the mobile terminal detects the cover sliding action, so that themobile terminal can perform subsequent operations.

According to a second aspect of the present disclosure, an unlockingdevice is provided, wherein the unlocking device includes: an acquiringunit, configured to acquire a face image through a camera of a mobileterminal in response to a cover sliding action on the mobile terminal;and an unlocking unit, configured to unlock the mobile terminal by usingthe face image.

In an implementation of the present disclosure, the unlocking unit isconfigured to: compare features between the face image and a preset faceimage to obtain a comparison result, and unlock the mobile terminal whenthe comparison result indicates that the face image and the preset faceimage are from the same person.

In an implementation of the present disclosure, the unlocking unit isfurther configured to light a screen and output a touch unlockinginterface when the comparison result indicates that the face image andthe preset face image are from different persons.

In an implementation of the present disclosure, the unlocking unit isfurther configured to light the screen and output a main menu interfaceafter the mobile terminal is unlocked.

In an implementation of the present disclosure, the device furtherincludes a detecting unit configured to: acquire a sliding eventparameter generated by a Hall sensor in the mobile terminal, anddetermine whether a cover sliding action occurs on the mobile terminalaccording to the sliding event parameter.

According to a third aspect of the present disclosure, there is providedan unlocking control mechanism for a mobile terminal, comprising aprocessor; and a memory configured to store an instruction executable bythe processor, wherein the processor is configured to: capture a faceimage through a camera of the mobile terminal in response to a slidingaction applied to a sliding module of the mobile terminal; and unlockthe mobile terminal by using the captured face image as a key.

According to a fourth aspect of the present disclosure, there isprovided a computer-readable storage medium having encoded thereoninstructions which, when executed by a processor of an unlockingmechanism of the first aspect above, would cause the unlocking mechanismto execute an unlocking method including: capturing a face image througha camera of the mobile terminal in response to a sliding action appliedto a sliding module of the mobile terminal; and unlocking the mobileterminal by using the captured face image as a key.

It is to be understood that, both the foregoing general description andthe following detailed description are exemplary and explanatory onlyand are not restrictive of the present disclosure.

BRIEF DESCRIPTION OF THE DRAWINGS

The accompanying drawings referred to in the specification are a part ofthis disclosure, and provide illustrative embodiments consistent withthe disclosure and, together with the detailed description, serve toillustrate some embodiments of the disclosure.

FIG. 1 shows a schematics drawing of a mobile terminal according to someembodiments of the present disclosure;

FIG. 2 shows a side view of the mobile terminal where the sliding moduleis in a retracted position;

FIG. 3 shows another side view of the mobile terminal where the slidingmodule is in an extended and exposed position;

FIG. 4 shows a flowchart of an unlocking method according to someembodiments;

FIG. 5 shows a flowchart of another unlocking method according to someembodiments;

FIG. 6 shows a front view of a mobile terminal in an unlocking processwith the sliding module in an exposed position according to someembodiments;

FIG. 7 shows an exemplary mobile terminal interface after successfulunlocking according to some embodiments;

FIG. 8 shows a block diagram representing the architecture of anunlocking mechanism according to some embodiments; and

FIG. 9 shows a block diagram of the unlocking mechanism according tosome embodiments.

DETAILED DESCRIPTION

Various embodiments of the present disclosure are described below withspecific examples, and other advantages and effects of the presentdisclosure can be easily understood by those skilled in the field oftechnology from the contents disclosed in this specification. Thefollowing description refers to the accompanying drawings in which samenumeral references in different drawings may represent the same orsimilar elements unless otherwise indicated.

Apparently, the described embodiments are only a part of embodiments inthe present disclosure, rather than all of them. The present disclosurecan also be implemented or applied through different specificembodiments, and various details of the specification can also bemodified or changed based on different viewpoints and applicationswithout departing from the spirit of the present disclosure.

The inventors of the present disclosure have recognized that, theconventional process for unlocking a mobile terminal is very tedious andrequires all the steps of turning on the screen by clicking the powerbutton, inputting the unlocking password or gesture into the unlockinginterface, and the like, which lead to a time-consuming and laboriousunlocking process.

Methods for a user to unlock mobile terminals as described herein areparticularly suited for sliding-cover style mobile terminals, whichgenerally are configured to have an all-screen mobile terminalpreferably having 100% screen-to-body ratio. In all-screen mobileterminals, because the screen takes up 100% of the terminal's frontsurface, the placement of a front-facing camera on the mobile terminalbecomes a real challenge. Accordingly, sliding-cover designs whichprovide a cover or panel that can be slid open with a sliding actionoffers a viable solution for the placement of the front camera. Thissliding-cover style mobile terminal will be briefly introduced belowwith reference to the accompanying drawings.

FIG. 1 is a schematic view showing an exemplary mobile terminal inaccordance with one embodiment of the present disclosure. Referring toFIG. 1, mobile terminal 10 has a front surface and a rear surface,wherein the front surface is the screen of the mobile terminal. Asliding module 20 that can slide vertically relative to the screen isprovided in the mobile terminal 10.

The various device components, blocks, or portions may have modularconfigurations, or are composed of discrete components, but nonethelessmay be referred to as “modules” in general. In other words, the“modules” referred to herein may or may not be in modular forms.

In some embodiments, such as those illustrated in FIG. 1, the slidingmodule 20 can be an insert or a block slidably coupled to a frame of themobile terminal 10. The sliding module 20 can be made of a materialsimilar or the same as that of the frame, such as plastic, metal,composite, etc.

In some other embodiments, the sliding module 20 can be implemented withpart of a touch screen of the mobile terminal 10. For example, bysliding the sliding module on the touch screen, a cover portion of thefront-facing camera 30 can become transparent, thereby “exposing” thefront-facing camera 30. On the other hand, an opposite sliding motion ora command input to the mobile terminal 10 can cause the cover portion tobecome opaque, thereby “hiding” or turning off the front-facing camera30.

Therefore, the sliding module 20 can be implemented with mechanicalmoving parts, or electronically with the screen of the mobile terminal10 to realize similar functions of hiding and exposing the front-facingcamera 30.

FIGS. 2 and 3 are side views of the same mobile terminal 10 shown inFIG. 1. Referring to FIGS. 2 and 3, a front-facing camera 30 is disposedon the sliding module 20. When the front-facing camera 30 is not in useand is hidden from view inside the mobile terminal 10, the slidingmodule 20 is in a retracted state, namely, inside the mobile terminal.At this time, the state of the entire mobile terminal 10 is as shown inFIGS. 1 and 2. When the front-facing camera 30 is required to be used,the sliding module 20 slides upward to be in a protruding state. At thistime, the front-facing camera 30 becomes exposed from the mobileterminal, as shown in FIG. 3, so that the front-facing camera 30 can beused for taking pictures.

In the mobile terminal 10 shown in FIG. 1, the sliding module 20 isshown as being sandwiched between the front surface and rear surface ofthe mobile terminal 10. That is, a sliding groove 40 is formed betweenthe front-facing screen and the rear body of the mobile terminal 10 suchthat the sliding module 20 moves vertically along the sliding groove 40.

In other embodiments, the sliding groove 40 may also be located at otherpositions of the mobile terminal 10, for example, on the rear cover ofthe mobile terminal 10. The sliding-cover style mobile terminaldescribed in the present disclosure does not put a limitation on thespecific structure and position of the sliding module, so long as thefront-facing camera can be exposed and hidden from view through asliding action that extends and retracts the sliding module relative tothe main body of the mobile terminal.

Mobile terminals in accordance with embodiments of this disclosure mayinclude, but are not limited to, cell phones, a tablet PCs, and thelike.

FIG. 4 shows a flowchart of a method for a user to unlock a mobileterminal according to one exemplary embodiment of this disclosure. Themethod may advantageously be executed by a mobile terminal describedherein. Referring to FIG. 4, unlocking methods in accordance with thisembodiment will generally include the following steps.

In step S11, a face image of the user is captured through a front-facingcamera of the mobile terminal in response to a sliding action applied tothe sliding module of the mobile terminal.

In this step, the sliding action refers to an action on or by thesliding module that exposes the front-facing camera. This action can bedetected by detecting the position of the sliding module through aposition sensor such as a Hall sensor in the mobile terminal.

In this step, the front-facing camera becomes exposed. At the same time,the front-facing camera is activated to capture a face image of theuser.

In step S12, the captured face image is used as a key to unlock themobile terminal.

In some preferred embodiments, the manner of unlocking the mobileterminal is by automatically recognizing the captured face image, ratherthan conventional means of using password, gesture or fingerprint, sothat a user needs not perform additional steps to effectuate unlockingof the terminal.

In some preferred embodiments, the front-facing camera of the mobileterminal is exposed by a user applying a sliding action to the slidingmodule. At the same time when the front-facing camera is exposed, thecamera is activated to capture a face image of the user and unlocks themobile terminal by automatically recognizing the face image captured. Inthe entire unlocking process, the user does not need to performadditional operational steps such as clicking a power button to turn onthe screen, and inputting an unlocking password or gesture on anunlocking interface, but only needs to expose the front-facing, cameraby moving the sliding module. It will be immediately appreciated bythose skilled in the art that such operation is simple and convenient,and requires less time and labor.

In addition, this solution avoids accidentally unlocking the terminalwhen the user merely desires to light up the screen to see the time,thereby saving the processing resources of the system.

In some alternate preferred embodiments, the step of unlocking themobile terminal by automatically recognizing the captured face image mayinclude: comparing features between the captured face image and a presetface image to obtain a comparison result; and unlocking the mobileterminal when the comparison result indicates that the captured faceimage and the preset face image are of the same person. If thecomparison result indicates that the captured face image and the presetface image are of different people, the terminal is not unlocked.

In these alternative embodiments, the features of the captured faceimage is compared with that of the preset face image in the mobileterminal to perform unlocking. That is, the mobile terminal can beunlocked successfully only when the captured face image and the presetface image are of the same person, thereby ensuring security of themobile terminal.

In some further alternative embodiments, the method further includes:lighting up a screen and presenting a touch unlocking interface when thecomparison result indicates that the captured face image and the presetface image are from different persons and the unlocking of the mobileterminal fails.

In these further embodiments, when unlocking by face image recognitionfails, the touch-based unlocking interface is presented to allow theuser to input a password or gesture for unlocking, so as to increase thediversity of unlocking manners.

In some other alternative embodiments, the method further includes:turning on the screen and presenting a main menu interface after themobile terminal is unlocked.

In these alternate embodiments, the screen is not lit (not turned on)when the front-facing camera is initially exposed, but is lighted up(turned on) as soon as the unlocking is successful so that the user doesnot need to wait for the unlocking when the screen is lit. Thus, notonly is power saved, but also the user feels that the unlocking speed ishigher, thereby improving the user's unlocking experience.

In still other embodiments, the method further includes: capturing asliding event parameter generated by a Hall sensor in the mobileterminal; and determining whether a sliding action has occurred on thesliding module in accordance with the sliding event parameter.

In these embodiments, when the user applies a sliding action on thesliding module, the Hall sensor in the mobile terminal detects thesliding action, so that the mobile terminal can perform subsequentoperations.

It should be noted that, the foregoing steps S11-S12 and the variousalternative embodiments may be combined randomly.

FIG. 5 is a flowchart of an unlocking method executed by a mobileterminal according to another exemplary embodiment. Referring to FIG. 5,the unlocking method includes the following steps.

In step S21, a sliding event parameter generated by a Hall sensor in themobile terminal is acquired.

In this step, whether a sliding action has occurred on the slidingmodule is determined in accordance with the sliding event parameter.Here the term “sliding action” refers to an action of exposing thefront-facing camera disposed on the sliding module, and can be detectedby a Hall sensor in the mobile terminal which may be arranged on a rearcover of the mobile terminal. Advantageously, the sliding module in themobile terminal is provided with a magnet. When the module slides, amagnetic field generated by the magnet changes; and the Hall sensor candetect the sliding action by detecting the change of the magnetic fieldand generate a sliding event parameter.

In some embodiments of the present disclosure, a processor of the mobileterminal acquires the sliding event parameter generated by the Hallsensor in the mobile terminal through a listener. In some embodiments,the sensor is managed by a sensor manager in the mobile terminal. Insuch embodiments, the processor of the mobile terminal needs to acquirea sensor service from the sensor manager and register the listener withthe sensor manager through the sensor service. Thus, when there is asliding event, the sensor process will notify the mobile terminalthrough the listener.

Taking an Android operating system as an example, a processor canacquire the sensor service from the sensor manager by executing thefollowing codes, and then register the listener.

mSensorManager=(SensorManager)context.getSystemService(Context.SENSOR_SER-  VICE); // acquiring the SENSOR_SERVICE from the SensorManagermSensor=mSensorManager.getDefaultSensor(SLIDE_COVER_SENSOR_TYPE, true);  //acquiring a Hall sensor parameter for detecting the cover slidingactionmSensorManager.registerListener(mListener,mSensor,SensorManager.SENSOR_DELAY  _NORMAL,mHandler); //registering the SensorEventListener Private finalSensorEventListener mListener = new SensorEventListener( ) {    @Override     Public void onSensorChanged(SensorEvent event) {//When the user slides the cover and the parameter SensorEvent eventsent by the Hall   sensor changes, the SensorEventListener outputs theparameter SensorEvent event     } }

The Hall sensor notifies whether a sliding action has occurred currentlyby reporting the parameter SensorEvent event, that is, the value of theparameter SensorEvent event indicates whether a sliding action hasoccurred. The parameter SensorEvent event includes a parameter value;and different values of the parameter correspond to different positionsof the module on which the front-facing camera resides. Therefore, theposition of the sliding module can be determined in accordance with thevalue of the parameter. That is, whether a sliding action has occurredcan be determined.

In step S22, whether a sliding action has occurred on the sliding moduleis determined in accordance with the sliding event parameter.

In this step, the processor determines whether a sliding action hasoccurred on the sliding module through a listener.

When the value of the SensorEvent event reported by the Hall sensor tothe listener corresponds to a true sliding action, the listener outputsthe parameter SensorEvent event to the processor, and the processor candetermine whether a sliding action has occurred on the sliding module inaccordance with the parameter SensorEvent event.

In step S23, when a sliding action occurs on the mobile terminal, a faceimage is captured by the front-facing camera of the mobile terminal.

When a user applies a sliding action to the sliding module, the Hallsensor in the mobile terminal detects the sliding action, and asliding-type event is generated. When the processor of the mobileterminal receives the sliding-type event, it is determined that the Hallsensor has detected a sliding action on the mobile terminal; and then, aface image is captured for recognition to unlock the mobile terminal.

In step S22, if there is a sliding-type event, it means that thefront-facing camera has been exposed. At this time, the front-facingcamera is activated to capture a face image of the user; and the faceimage as captured is recognized for unlocking.

In this step, capturing the face image through the front-facing cameraof the mobile terminal may include: detecting whether there is a face ina current image frame; and capturing the face image when there is a facein the current image frame.

Here, detecting whether there is a face in the current image frame canbe implemented through a classifier. Suitable classifiers are known inthe art and is not necessary to be repeated here.

In other embodiments, capturing a face image through the front-facingcamera of the mobile terminal may include: loading an image capturinginterface; and capturing a face image in response to the user's imagecapturing instruction. In this way, the user himself takes a picture ofhis face without an automated face detection process.

In step S24, the face image is recognized to unlock the mobile terminal.

When the face image fails to unlock the mobile terminal, step S25 isexecuted; and when the face image succeeds to unlock the mobileterminal, step S26 is executed.

In some embodiments, the manner of unlocking is by automaticallyrecognizing the captured face image, rather than conventional manners ofusing password, gesture or fingerprint, so that a user needs not performany additional operation.

In some further embodiments, unlocking the mobile terminal byrecognizing the face image includes: comparing features between the faceimage and a preset face image to obtain a comparison result; andunlocking the mobile terminal when the comparison result indicates thatthe face image and the preset face image are from the same person; andif the comparison result indicates that the face image and the presetface image are from different persons, unlocking of the mobile terminalfails.

In the above embodiments, the features of the face image captured by thefront-facing camera are compared with those of the preset face image inthe mobile terminal to perform unlocking. The mobile terminal can onlybe successfully unlocked when the face image as captured and the presetface image are from the same person, which ensures security of themobile terminal.

Here, comparing the features between the face image and a preset faceimage may include calling a face recognition algorithm to comparefeatures between the face image and the preset face image. For example,a face recognition algorithm is preset in the mobile terminal system.When comparing the features, the acquired face image is directly sent tothe face recognition subroutine implementing the algorithm, which thendetermines whether the face features in the face image and those in thepreset face image input in advance are consistent or not. If yes, itmeans that the face image and the preset face image are from the sameperson; and if not, it means that the face image and the preset faceimage are from different persons.

Here, the face recognition algorithm determines whether the face imageand the preset face image are from the same person by extracting featurepoints from the face image and then comparing the feature points withthose in the preset face image input in advance through a featureanalysis method. The foregoing feature analysis method may be ageometric feature analysis method, a local feature analysis method, afeature face method, an elastic model method, a neural network method,or the like.

In some embodiments, the face recognition algorithm may be an existingface recognition algorithm, such as a face recognition algorithmprovided by SenseTime, or any other suitable face recognition algorithmcommonly known in the art.

Further, prior to comparing the features between the face image and thepreset face image, the method may further include preprocessing the faceimage. The preprocessing may include: recognizing a face region in theface image; and cropping the face region in the face image to obtain aface image of a set size. Then, the comparison process is performed byusing the face image of a set size.

Further, the method may also include: acquiring a preset face image. Amanner of acquiring the preset face image may be the same as the processof capturing the face image in steps S23 and S24, which are not repeatedherein.

A setting option of the mobile terminal may include a preset face imagesetting item through which the user may input the preset face image.

Further, the preset face image may include face images of the same userfrom different angles, so as to improve the accuracy of unlockingthrough the face image.

The preset face image may include preset face images of a plurality ofusers, so that the mobile terminal may be unlocked by the plurality ofusers. When the preset face image includes the preset face images of aplurality of users, the comparing process in step S23 includes:sequentially comparing features of the face images shot by the frontcamera with the features of the preset face images of each of the users.

In step S25, a screen is lighted up and a touch unlocking interface ispresented.

The touch unlocking interface may be a password unlocking interface, agesture unlocking interface, or a fingerprint unlocking interface. Whenthe face image unlocking fails, the touch unlocking interface may bepresented to allow the user to enter a password, gesture or fingerprintfor unlocking, thereby increasing the diversity of the unlockingmanners.

Step S25 is an optional step. When there is no step S25, as theunlocking fails, the mobile terminal would not light up the screen andremain in a locked state. Subsequently, the user can light up the screenthrough a power button. Then, the mobile terminal receives a screenlighting instruction from the user, and presents the touch unlockinginterface to allow the user to perform touch unlocking.

Further, the method may also include: receiving a password, gesture orfingerprint input by the user through the touch unlocking interface; andusing the password, gesture or fingerprint as an unlocking key.

Further, the method may also include: receiving a password, gesture orfingerprint input by the user through the touch unlocking interface;comparing features between the password, gesture or fingerprint and theunlocking key; executing step S26 if the password, gesture orfingerprint and the unlocking key are the same, or presenting anunlocking failure prompt if the password, gesture or fingerprint and theunlocking key are different.

In step S26, the screen is lighted up and a main menu interface ispresented.

In this embodiment, the screen is not lighted when the front-facingcamera is initially exposed, but is lighted immediately after theunlocking is successful so that the user does not have to wait for theunlocking process to have the screen is lighted. Thus, not only is powersaved, but also the user feels that the unlocking speed is higher,improving the user unlocking experience.

Prior to the sliding action occurring, the state of the mobile terminalis as shown in FIG. 1. At this time, the front-facing camera is in aretracted state, and the screen is turned off. FIG. 6 is a schematicview of a mobile terminal interface displayed in an unlocking process.Referring to FIG. 6, when a sliding action occurs, the front-facingcamera 30 would be exposed, but the screen is still not lighted at thistime. FIG. 7 is a schematic view of the mobile terminal interface aftersuccessful unlocking. Referring to FIG. 7, after the front-facing camera30 completes the face image capturing and the unlocking is successfullyachieved by recognizing the captured face image, the screen is lightedand the main menu interface is displayed.

In other alternate embodiments, step S26 may also be implemented in thefollowing manner: in step S23, lighting the screen of the mobileterminal and displaying an unlocking interface when the front-facingcamera is initially exposed; and, after unlocking the mobile terminal,in step S26, displaying the main menu interface.

Further, an enable button of a sliding unlocking function may be presetin the mobile terminal, and may be set in a setting menu of the system.The user may select whether to enable the sliding unlocking functionthrough the enable button. Correspondingly, the mobile terminal receivesa user's enable button selection instruction, and controls the slidingunlocking function to be enabled or disabled in accordance with theenable button selection instruction. When the sliding unlocking functionis enabled, the mobile terminal executes steps S21-S26. When the slidingunlocking function is disabled, the mobile terminal does not executesteps S21-S26.

FIG. 8 is a block diagram showing an exemplary architecture of anunlocking device or mechanism according to some embodiments. Referringto FIG. 8, the unlocking device or mechanism includes an acquiring unit301, an unlocking unit 302, and, optionally, a detecting unit 303. Itwill be understood that the device or mechanism of FIG. 8 is an integralpart of a mobile terminal.

Referring again to FIG. 8, the acquiring unit 301 is configured toacquire a face image through a front-facing camera of the mobileterminal in response to a sliding action on the mobile terminal. Theunlocking unit 302 is configured to unlock the mobile terminal byrecognizing the face image as a key.

In some embodiments, the unlocking unit 302 is configured to comparefeatures between the face image and a preset face image to obtain acomparison result, and unlock the mobile terminal when the comparisonresult indicates that the face image and the preset face image are fromthe same person; and if the comparison result indicates that the faceimage and the preset face image are from different persons, theunlocking of the mobile terminal fails.

In some embodiments, the unlocking unit 302 is further configured tolight up the screen and present a touch-based unlocking interface whenthe comparison result indicates that the face image and the preset faceimage are from different persons and the unlocking of the mobileterminal fails.

In some embodiments, the unlocking unit 302 is further configured tolight up the screen and present a main menu interface after the mobileterminal is unlocked.

In some embodiments, the device further includes a detecting unit 303.The detecting unit 303 is configured to acquire a sliding eventparameter generated by a Hall sensor in the mobile terminal, and thendetermine whether a sliding action has occurred on the sliding module inaccordance with the sliding event parameter.

A manner through which the acquiring unit 301 acquires the face imagemay refer to step S23. A manner through which the unlocking unit 302unlocks the mobile terminal may refer to step S24. Detailed descriptionsof these manners are omitted herein.

FIG. 9 is a block diagram of an exemplary unlocking mechanism 600 shownaccording to one exemplary embodiment. The mechanism 600 may be setwithin a mobile phone as mentioned above. Referring to FIG. 9, theunlocking mechanism 600 may include one or more of the followingcomponents: a processing component 602, a memory 604, a power component606, a multimedia component 608, an audio component 610, an input/output(I/O) interface 612, a sensor component 614, and a communicationcomponent 616.

The processing component 602 typically controls the overall operationsof the unlocking mechanism 600, such as the operations associated withdisplay, telephone calls, data communications, camera operations, andrecording operations. The processing component 602 may include one ormore processors 620 to execute instructions to perform all or part ofthe steps in the above described methods. Moreover, the processingcomponent 602 may include one or more modules which facilitate theinteraction between the processing component 602 and other components.For instance, the processing component 602 may include a multimediamodule to facilitate the interaction between the multimedia component608 and the processing component 602.

The memory 604 is configured to store various types of data to supportthe operation on the unlocking mechanism 600. Examples of such datainclude instructions for any applications or methods to be operative viathe unlocking mechanism 600, contact data, phonebook data, messages,pictures, videos, etc. The memory 604 may be implemented by using anytype of volatile or non-volatile memory devices, or a combinationthereof, such as a static random access memory (SRAM), an electricallyerasable programmable read-only memory (EEPROM), an erasableprogrammable read-only memory (EPROM), a programmable read-only memory(PROM), a read-only memory (ROM), a magnetic memory, a flash memory, amagnetic or optical disk.

The power component 606 provides power to various components of thedevice 600. The power component 606 may include a power managementsystem, one or more power sources, and any other components associatedwith the generation, management, and distribution of power in theunlocking mechanism 600.

The multimedia component 608 includes a screen providing an outputinterface between the unlocking mechanism 600 and the user. In someembodiments, the screen may include a liquid crystal display (LCD) and atouch panel (TP). If the screen includes a touch panel, the screen maybe implemented as a touch screen to receive input signals from the user.The touch panel includes one or more touch sensors to sense touches,swipes, and gestures on the touch panel. The touch sensors may not onlysense a boundary of a touch or swipe action, but also sense the durationand pressure associated with the touch or swipe action. In someembodiments, the multimedia component 608 includes a front-facing cameraand/or a rear-facing camera. The front-facing camera and the rear-facingcamera may capture image or video data while the unlocking mechanism 600is in an operation mode, such as an acquiring mode or a video mode. Eachof the front-facing camera and the rear-facing camera may be a fixedoptical lens system or have focus and optical zoom capability.

The audio component 610 is configured to output and/or input audiosignals. For example, the audio component 610 includes a microphone(MIC) configured to receive external audio signals when the unlockingmechanism 600 is in an operation mode, such as a call mode, a recordingmode, and a voice recognition mode. The received audio signal may befurther stored in the memory 604 or transmitted via the communicationcomponent 616. In some embodiments, the audio component 610 furtherincludes a speaker for outputting audio signals.

The I/O interface 612 provides an interface between the processingcomponent 602 and peripheral interface modules, such as a keyboard, aclick wheel, buttons, and the like. The buttons may include, but are notlimited to, a home button, a volume button, a start button, and a lockbutton.

The sensor component 614 includes one or more sensors to provide statusassessments of various aspects of the unlocking mechanism 600. Forinstance, the sensor component 614 may include a Hall sensor fordetecting the sliding action of the unlocking mechanism 600. The sensorcomponent 614 may detect an on/off status of the unlocking mechanism600, relative positioning of components, e.g., the display device andthe mini keyboard operatively coupled with the unlocking mechanism 600,and the sensor component 614 may also detect a position change in theunlocking mechanism 600 or a component of the unlocking mechanism 600,presence or absence of user contact with the unlocking control mechanism600, orientation or acceleration/deceleration of the unlocking controlmechanism 600, and temperature change(s) in the unlocking controlmechanism 600. The sensor component 614 may include a proximity sensorconfigured to detect the presence of nearby objects without any physicalcontact. The sensor component 614 may also include a light sensor, suchas a CMOS or CCD image sensor, used in connection with imagingapplications. In some embodiments, the sensor component 614 may alsoinclude an accelerometer sensor, a gyroscope sensor, a magnetic sensor,a pressure sensor, or a temperature sensor.

The communication component 616 is configured to facilitatecommunication, in a wired or wireless manner, between the unlockingcontrol mechanism 600 and other devices. In an embodiment of the presentdisclosure, the communication component 616 can access a wirelessnetwork based on a communication standard, such as 2G, 3G, 4G, or 5G, ora combination thereof, so as to implement a physical downlink controlsignaling detection. In some embodiments, the communication component616 receives broadcast signals or broadcast associated information froman external broadcast management system via a broadcast channel.Optionally, the communication component 616 further includes a nearfield communication (NFC) module.

In some embodiments, the unlocking control mechanism 600 may beimplemented with one or more application specific integrated circuits(ASICs), digital signal processors (DSPs), digital signal processingdevices (DSPDs), programmable logic devices (PLDs), field programmablegate arrays (FPGAs), controllers, micro-controllers, microprocessors, orother electronic components, for performing the above describedunlocking methods.

In some embodiments, a non-transitory computer-readable storage mediumincluding instructions is also provided, such as the memory 604including instructions, executable by the processor 620 in the unlockingcontrol mechanism 600, for performing the above-described unlockingmethods. For example, the non-transitory computer-readable storagemedium may be a ROM, a RAM, a CD-ROM, a magnetic tape, a floppy disc, anoptical data storage device, and the like.

The terms “first” and “second” are used for descriptive purposes onlyand are not to be construed as indicating or implying a relativeimportance or implicitly indicating the number of technical featuresindicated. Thus, elements referred to as “first” and “second” mayinclude one or more of the features either explicitly or implicitly. Inthe description of the present disclosure, “a plurality” indicates twoor more unless specifically defined otherwise.

In the present disclosure, the terms “installed,” “connected,”“coupled,” “fixed” and the like shall be understood broadly, and may beeither a fixed connection or a detachable connection, or integrated,unless otherwise explicitly defined. These terms can refer to mechanicalor electrical connections, or both. Such connections can be directconnections or indirect connections through an intermediate medium.These terms can also refer to the internal connections or theinteractions between elements. The specific meanings of the above termsin the present disclosure can be understood by those of ordinary skillin the art on a case-by-case basis.

In the description of the present disclosure, the terms “oneembodiment,” “some embodiments,” “example,” “specific example,” or “someexamples,” and the like may indicate a specific feature described inconnection with the embodiment or example, a structure, a material orfeature included in at least one embodiment or example. In the presentdisclosure, the schematic representation of the above terms is notnecessarily directed to the same embodiment or example.

It will be understood that when an element such as a layer, region, orother structure is referred to as being “on” or extending “onto” anotherelement, it can be directly on or extend directly onto the other elementor intervening elements can also be present. In contrast, when anelement is referred to as being “directly on” or extending “directlyonto” another element, there are no intervening elements present.

Likewise, it will be understood that when an element such as a layer,region, or substrate is referred to as being “over” or extending “over”another element, it can be directly over or extend directly over theother element or intervening elements can also be present. In contrast,when an element is referred to as being “directly over” or extending“directly over” another element, there are no intervening elementspresent. It will also be understood that when an element is referred toas being “connected” or “coupled” to another element, it can be directlyconnected or coupled to the other element or intervening elements can bepresent. In contrast, when an element is referred to as being “directlyconnected” or “directly coupled” to another element, there are nointervening elements present.

Relative terms such as “up” or “down” or “left” or “right” or “below” or“above” or “upper” or “lower” or “horizontal” or “vertical” can be usedherein to describe a relationship of one element, layer, or region toanother element, layer, or region as illustrated in the drawings. Itwill be understood that these terms and those discussed above areintended to encompass different orientations of the device in additionto the orientation depicted in the drawings.

The terminology used herein is for the purpose of describing particularembodiments only and is not intended to be limiting of the disclosure.As used herein, the singular forms “a,” “an,” and “the” are intended toinclude the plural forms as well, unless the context clearly indicatesotherwise. It will be further understood that the terms “comprises,”“comprising,” “includes,” and/or “including” when used herein specifythe presence of stated features, integers, steps, operations, elements,and/or components, but do not preclude the presence or addition of oneor more other features, integers, steps, operations, elements,components, and/or groups thereof.

Unless otherwise defined, all terms (including technical and scientificterms) used herein have the same meaning as commonly understood by oneof ordinary skill in the art to which this disclosure belongs. It willbe further understood that terms used herein should be interpreted ashaving a meaning that is consistent with their meaning in the context ofthis specification and the relevant art and will not be interpreted inan idealized or overly formal sense unless expressly so defined herein.

Moreover, the particular features, structures, materials, orcharacteristics described may be combined in a suitable manner in anyone or more embodiments or examples. In addition, various embodiments orexamples described in the specification, as well as features of variousembodiments or examples, may be combined and reorganized.

In some embodiments, the control and/or interface software or app can beprovided in a form of a non-transitory computer-readable storage mediumhaving instructions stored thereon is further provided. For example, thenon-transitory computer-readable storage medium may be a ROM, a RAM, aCD-ROM, a magnetic tape, a floppy disk, optical data storage equipment,a flash drive such as a USB drive or an SD card, and the like.

Implementations of the subject matter and the operations described inthis disclosure can be implemented in digital electronic circuitry, orin computer software, firmware, or hardware, including the structuresdisclosed herein and their structural equivalents, or in combinations ofone or more of them. Implementations of the subject matter described inthis disclosure can be implemented as one or more computer programs,i.e., one or more portions of computer program instructions, encoded onone or more computer storage medium for execution by, or to control theoperation of, data processing apparatus.

Alternatively, or in addition, the program instructions can be encodedon an artificially-generated propagated signal, e.g., amachine-generated electrical, optical, or electromagnetic signal, thatis generated to encode information for transmission to suitable receiverapparatus for execution by a data processing apparatus. A computerstorage medium can be, or be included in, a computer-readable storagedevice, a computer-readable storage substrate, a random or serial accessmemory array or device, or a combination of one or more of them.

Moreover, while a computer storage medium is not a propagated signal, acomputer storage medium can be a source or destination of computerprogram instructions encoded in an artificially-generated propagatedsignal. The computer storage medium can also be, or be included in, oneor more separate components or media (e.g., multiple CDs, disks, drives,or other storage devices). Accordingly, the computer storage medium maybe tangible.

The operations described in this disclosure can be implemented asoperations performed by a data processing apparatus on data stored onone or more computer-readable storage devices or received from othersources.

The devices in this disclosure can include special purpose logiccircuitry, e.g., an FPGA (field-programmable gate array), or an ASIC(application-specific integrated circuit). The device can also include,in addition to hardware, code that creates an execution environment forthe computer program in question, e.g., code that constitutes processorfirmware, a protocol stack, a database management system, an operatingsystem, a cross-platform runtime environment, a virtual machine, or acombination of one or more of them. The devices and executionenvironment can realize various different computing modelinfrastructures, such as web services, distributed computing, and gridcomputing infrastructures.

A computer program (also known as a program, software, softwareapplication, app, script, or code) can be written in any form ofprogramming language, including compiled or interpreted languages,declarative or procedural languages, and it can be deployed in any form,including as a stand-alone program or as a portion, component,subroutine, object, or other portion suitable for use in a computingenvironment. A computer program may, but need not, correspond to a filein a file system. A program can be stored in a portion of a file thatholds other programs or data (e.g., one or more scripts stored in amarkup language document), in a single file dedicated to the program inquestion, or in multiple coordinated files (e.g., files that store oneor more portions, sub-programs, or portions of code). A computer programcan be deployed to be executed on one computer or on multiple computersthat are located at one site or distributed across multiple sites andinterconnected by a communication network.

The processes and logic flows described in this disclosure can beperformed by one or more programmable processors executing one or morecomputer programs to perform actions by operating on input data andgenerating output. The processes and logic flows can also be performedby, and apparatus can also be implemented as, special purpose logiccircuitry, e.g., an FPGA, or an ASIC.

Processors suitable for the execution of a computer program include, byway of example, both general and special purpose microprocessors, andany one or more processors of any kind of digital computer. Generally, aprocessor will receive instructions and data from a read-only memory, ora random-access memory, or both. Elements of a computer can include aprocessor configured to perform actions in accordance with instructionsand one or more memory devices for storing instructions and data.

Generally, a computer will also include, or be operatively coupled toreceive data from or transfer data to, or both, one or more mass storagedevices for storing data, e.g., magnetic, magneto-optical disks, oroptical disks. However, a computer need not have such devices. Moreover,a computer can be embedded in another device, e.g., a mobile telephone,a personal digital assistant (PDA), a mobile audio or video player, agame console, a Global Positioning System (GPS) receiver, or a portablestorage device (e.g., a universal serial bus (USB) flash drive), to namejust a few.

Devices suitable for storing computer program instructions and datainclude all forms of non-volatile memory, media and memory devices,including by way of example semiconductor memory devices, e.g., EPROM,EEPROM, and flash memory devices; magnetic disks, e.g., internal harddisks or removable disks; magneto-optical disks; and CD-ROM and DVD-ROMdisks. The processor and the memory can be supplemented by, orincorporated in, special purpose logic circuitry.

To provide for interaction with a user, implementations of the subjectmatter described in this specification can be implemented with acomputer and/or a display device, e.g., a VR/AR device, a head-mountdisplay (HMD) device, a head-up display (HUD) device, smart eyewear(e.g., glasses), a CRT (cathode-ray tube), LCD (liquid-crystal display),OLED (organic light emitting diode), TFT (thin-film transistor), plasma,other flexible configuration, or any other monitor for displayinginformation to the user and a keyboard, a pointing device, e.g., amouse, trackball, etc., or a touch screen, touch pad, etc., by which theuser can provide input to the computer.

Implementations of the subject matter described in this specificationcan be implemented in a computing system that includes a back-endcomponent, e.g., as a data server, or that includes a middlewarecomponent, e.g., an application server, or that includes a front-endcomponent, e.g., a client computer having a graphical user interface ora Web browser through which a user can interact with an implementationof the subject matter described in this specification, or anycombination of one or more such back-end, middleware, or front-endcomponents. The components of the system can be interconnected by anyform or medium of digital data communication, e.g., a communicationnetwork. Examples of communication networks include a local area network(“LAN”) and a wide area network (“WAN”), an inter-network (e.g., theInternet), and peer-to-peer networks (e.g., ad hoc peer-to-peernetworks).

While this specification contains many specific implementation details,these should not be construed as limitations on the scope of any claims,but rather as descriptions of features specific to particularimplementations. Certain features that are described in thisspecification in the context of separate implementations can also beimplemented in combination in a single implementation. Conversely,various features that are described in the context of a singleimplementation can also be implemented in multiple implementationsseparately or in any suitable subcombination.

Moreover, although features may be described above as acting in certaincombinations and even initially claimed as such, one or more featuresfrom a claimed combination can in some cases be excised from thecombination, and the claimed combination may be directed to asubcombination or variation of a subcombination.

Similarly, while operations are depicted in the drawings in a particularorder, this should not be understood as requiring that such operationsbe performed in the particular order shown or in sequential order, orthat all illustrated operations be performed, to achieve desirableresults. In certain circumstances, multitasking and parallel processingmay be advantageous. Moreover, the separation of various systemcomponents in the implementations described above should not beunderstood as requiring such separation in all implementations, and itshould be understood that the described program components and systemscan generally be integrated together in a single software product orpackaged into multiple software products.

Thus, particular implementations of the subject matter have beendescribed. Other implementations are within the scope of the followingclaims. In some cases, the actions recited in the claims can beperformed in a different order and still achieve desirable results. Inaddition, the processes depicted in the accompanying figures do notnecessarily require the particular order shown, or sequential order, toachieve desirable results. In certain implementations, multitasking orparallel processing may be utilized.

It is intended that the specification and embodiments be considered asexamples only. Other embodiments of the disclosure will be apparent tothose skilled in the art in view of the specification and drawings ofthe present disclosure. That is, although specific embodiments have beendescribed above in detail, the description is merely for purposes ofillustration. It should be appreciated, therefore, that many aspectsdescribed above are not intended as required or essential elementsunless explicitly stated otherwise.

Various modifications of, and equivalent acts corresponding to, thedisclosed aspects of the example embodiments, in addition to thosedescribed above, can be made by a person of ordinary skill in the art,having the benefit of the present disclosure, without departing from thespirit and scope of the disclosure defined in the following claims, thescope of which is to be accorded the broadest interpretation so as toencompass such modifications and equivalent structures.

The invention claimed is:
 1. A method for a user to unlock a mobileterminal, comprising: acquiring, by using a listener, a sliding eventparameter generated by a Hall sensor in the mobile terminal, wherein thesliding event parameter is output by the listener registered through asensor service of the Hall sensor when the sliding event parameter sentby the Hall sensor changes; determining whether a sliding action hasoccurred on a sliding module of the mobile terminal according to thesliding event parameter; capturing a face image of the user through afront-facing camera of the mobile terminal in response to a slidingaction applied to the sliding module of the mobile terminal; andunlocking the mobile terminal by using the captured face image of theuser as a key, wherein said front-facing camera is disposed on thesliding module, and different values of the sliding event parametercorrespond to different positions of the sliding module.
 2. The methodof claim 1, wherein unlocking the mobile terminal by using the capturedface image comprises: comparing features between the captured face imageand a preset face image to obtain a comparison result; and unlocking themobile terminal when the comparison result indicates that the face imageand the preset face image are from the same person.
 3. The method ofclaim 2, further comprising: turning on a screen of the mobile terminaland presenting a touch-based unlocking interface when the comparisonresult indicates that the captured face image and the preset face imageare from different persons.
 4. The method of claim 2, furthercomprising: turning on a screen of the mobile terminal and presenting amain menu interface immediately after the mobile terminal is unlocked.5. A mobile terminal having an unlocking mechanism, comprising: ascreen; a sliding module having a front-facing camera disposed thereon;a processor; and a memory configured to store an instruction executableby the processor, wherein the processor is configured to: acquiring, byusing a listener, a sliding event parameter generated by a Hall sensorin the mobile terminal, wherein the sliding event parameter is output bythe listener registered through a sensor service of the Hall sensor whenthe sliding event parameter sent by the Hall sensor changes, whereindifferent values of the sliding event parameter correspond to differentpositions of the sliding module; determining whether a sliding actionhas occurred on the sliding module of the mobile terminal according tothe sliding event parameter; analyze a face image of a user capturedthrough the front-facing camera disposed on the sliding module of themobile terminal in response to a sliding action applied to the slidingmodule; and unlock the mobile terminal by using the captured face imageas a key.
 6. The mobile terminal of claim 5, wherein unlocking themobile terminal by using the captured face image comprises: comparingfeatures between the face image and a preset face image to obtain acomparison result; and unlocking the mobile terminal when the comparisonresult indicates that the face image and the preset face image are fromthe same person.
 7. The mobile terminal of claim 6, wherein theprocessor is further configured to: turn on the screen and present atouch-based unlocking interface when the comparison result indicatesthat the face image and the preset face image are from differentpersons.
 8. The mobile terminal of claim 6, wherein the processor isfurther configured to: turn on the screen and present a main menuinterface immediately after the mobile terminal is unlocked.
 9. Anon-transitory computer-readable storage medium having instructionsstored therein for execution by a processor to cause a mobile terminalhaving a sliding module and a front-facing camera disposed on saidsliding module to execute an unlocking method comprising: acquiring, byusing a listener, a sliding event parameter generated by a Hall sensorin the mobile terminal, wherein the sliding event parameter is output bythe listener registered through a sensor service of the Hall sensor whenthe sliding event parameter sent by the Hall sensor changes, whereindifferent values of the sliding event parameter correspond to differentpositions of the sliding module; determining whether a sliding actionhas occurred on the sliding module of the mobile terminal according tothe sliding event parameter; capturing a face image of a user throughthe front-facing camera in response to a sliding action applied on thesliding module; and unlocking the mobile terminal by using the capturedface image as a key.
 10. The computer-readable storage medium of claim9, wherein unlocking the mobile terminal by using the captured faceimage comprises: comparing features between the captured face image anda preset face image to obtain a comparison result; and unlocking themobile terminal when the comparison result indicates that the face imageand the preset face image are from the same person.
 11. Thecomputer-readable storage medium of claim 10, wherein the method furthercomprises: turning on a screen of the mobile terminal and presenting atouch-based unlocking interface when the comparison result indicatesthat the face image and the preset face image are from differentpersons.
 12. The computer-readable storage medium of claim 10, whereinthe method further comprises: turning on a screen of the mobile terminaland presenting a main menu interface immediately after the mobileterminal is unlocked.
 13. The mobile terminal of claim 6, wherein: thescreen is a front-facing screen, and the mobile terminal furthercomprises a rear body; a sliding grove is formed between thefront-facing screen and the rear body; and the sliding module isconfigured to be sandwiched between the front-facing screen and the rearbody, and move vertically along the sliding groove to expose thefront-facing camera and realize the sliding action.
 14. The mobileterminal of claim 13, wherein the mobile terminal is configured to beunlocked without the user pressing a power button to turn on the screen,thereby avoiding the user waiting for the unlocking with the screenturned on, saving power while improving unlocking speed.
 15. The mobileterminal of claim 14, wherein the mobile terminal is configured to beunlocked without the user inputting an unlocking password or a gestureon an unlocking interface.
 16. The mobile terminal of claim 15, whereinthe mobile terminal is configured to be unlocked with a single operationof the sliding action.